package com.foredu.fiqs.domain;

import java.io.Serializable;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.PrimaryKeyJoinColumn;
import javax.persistence.Table;

/**
 * Description:<br/>
 * 领域模型：职工类，代表湖北职院的所有职工(教师/行政/后勤等)<br/>
 * Date:<br/>
 * 2014/5/13<br/>
 * 
 * @author hushigang
 */

@Entity
@Table(name = "T_Employee")
@PrimaryKeyJoinColumn(name = "user_id")
public class Employee extends User implements Serializable {

	private static final long serialVersionUID = 1L;
	private String empId;// 职工编号
	private EmpPost empPost;// 职工职务
	private EmpTitle empTitle;// 职工职称
	private EmpType empType;// 职工类别
	private Department department;// 所属部门
	private int status;// 工作状态，1代表在职，0代表离职
	private String empDay;// 入职时间
	private String idCard;// 身份证号码
	private String bankCard;// 银行账号

	@Column
	public String getEmpId() {
		return empId;
	}

	public void setEmpId(String empId) {
		this.empId = empId;
	}

	@ManyToOne
	@JoinColumn(name = "empPost_id")
	public EmpPost getEmpPost() {
		return empPost;
	}

	public void setEmpPost(EmpPost empPost) {
		this.empPost = empPost;
	}

	@ManyToOne
	@JoinColumn(name = "empTitle_id")
	public EmpTitle getEmpTitle() {
		return empTitle;
	}

	public void setEmpTitle(EmpTitle empTitle) {
		this.empTitle = empTitle;
	}

	@ManyToOne
	@JoinColumn(name = "empType_id")
	public EmpType getEmpType() {
		return empType;
	}

	public void setEmpType(EmpType empType) {
		this.empType = empType;
	}

	@ManyToOne
	@JoinColumn(name = "dept_id")
	public Department getDepartment() {
		return department;
	}

	public void setDepartment(Department department) {
		this.department = department;
	}

	@Column
	public int getStatus() {
		return status;
	}

	public void setStatus(int status) {
		this.status = status;
	}

	@Column
	public String getEmpDay() {
		return empDay;
	}

	public void setEmpDay(String empDay) {
		this.empDay = empDay;
	}

	@Column
	public String getIdCard() {
		return idCard;
	}

	public void setIdCard(String idCard) {
		this.idCard = idCard;
	}

	@Column
	public String getBankCard() {
		return bankCard;
	}

	public void setBankCard(String bankCard) {
		this.bankCard = bankCard;
	}

}
